package com.zerox.order.config;

import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.client.RestTemplate;

/**
 * @auth wzy
 * @date 2023/3/15 11:40
 */
@Configuration
public class ApplicationContextConfig {

    //创建RestTemplate类的bean实例对象
    @Bean
    @LoadBalanced
    public RestTemplate getRestTemplate() {
        return new RestTemplate();
    }

}
